<load target="../../admin/tpl/css/admin.bootstrap.css" />
<load target="../../admin/tpl/css/admin.css" />
<load cond="$lang_type=='ko'" target="../../admin/tpl/css/admin_ko.css" />
<load cond="$lang_type=='en'" target="../../admin/tpl/css/admin_en.css" />
<load target="../../admin/tpl/js/admin.js" />
<load target="js/generate_code.js" />
<load target="../../admin/tpl/js/jquery.tmpl.js" />
<load target="../../admin/tpl/js/jquery.jstree.js" />
<script>
	xe.lang.cmd_delete = '{$lang->cmd_delete}';

	jQuery(document).ready(function(){
		doFillWidgetVars();
	});
</script>
<div class="x">
	<div class="x_modal-header">
		<h1>{$widget_info->title} {$lang->cmd_generate_code}</h1>
	</div>
	<div id="content" class="x_modal-body">
		<p>{$widget_info->description} {$lang->about_widget_code_in_page}</p>
		<form cond="$type=='faceoff'" class="x_form-horizontal">
			<input type="hidden" name="module" value="widget" />
			<input type="hidden" name="type" value="faceoff" />
			<input type="hidden" name="act" value="dispWidgetGenerateCodeInPage" />
			<input type="hidden" name="error_return_url" value="" />
			<div class="x_control-group">
				<label for="selected_widget" class="x_control-label">
					{$lang->widget}
				</label>
				<div class="x_controls">
					<select name="selected_widget" id="selected_widget" style="margin:0">
						<option loop="$widget_list => $list_widget_info" value="{$list_widget_info->widget}">{$list_widget_info->title}</option>
					</select>
					<input type="submit" value="{$lang->cmd_select}" class="x_btn" />
				</div>
			</div>
		</form>
		<form class="x_form-horizontal" action="./" method="post" id="fo_widget">
			<input type="hidden" name="module" value="widget" />
			<input type="hidden" name="module_srl" value="{$module_srl}" />
			<input type="hidden" name="widget_sequence" value="" />
			<input type="hidden" name="style" value="float:left;width:100%;margin:none;padding:none;" />
			<input type="hidden" name="widget_padding_left" value="" />
			<input type="hidden" name="widget_padding_right" value="" />
			<input type="hidden" name="widget_padding_top" value="" />
			<input type="hidden" name="widget_padding_bottom" value="" />
			<input type="hidden" name="selected_widget" value="{$widget_info->widget}" />

			<include target="widget_generate_code.include.html" />

			<div class="btnArea">
				<input type="submit" class="x_btn x_btn-primary" value="{$lang->cmd_generate_code}" />
			</div>
		</form>
	</div>

	<include target="../../module/tpl/include.filebox.html" />
</div>
